# Contributor: Francesco Colista <fcolista@alpinelinux.org>
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=py3-simplejson
_pkgname=simplejson
pkgver=3.17.6
pkgrel=0
pkgdesc="Simple, fast, extensible JSON encoder/decoder for Python"
url="https://pypi.python.org/pypi/simplejson"
arch="all"
license="MIT"
depends="python3"
makedepends="py3-setuptools python3-dev"
source="https://github.com/simplejson/simplejson/archive/refs/tags/v$pkgver/simplejson-v$pkgver.tar.gz"
builddir="$srcdir"/$_pkgname-$pkgver

provides="py-simplejson=$pkgver-r$pkgrel" # backwards compatibility
replaces="py-simplejson" # backwards compatiblity

build() {
	python3 setup.py build
}

check() {
	python3 setup.py test
}

package() {
	python3 setup.py install --prefix=/usr --root="$pkgdir"
	rm -Rf "$pkgdir"/usr/lib/python*/site-packages/simplejson/tests/
}

sha512sums="
48b74388cd3a5cf0acf46a9aa050d628513d842297625f791c7ae07a7c9289afcb0be8d374f77af3bebd50f4c200844bc69f5b77a67220fee357cdfc0d913726  simplejson-v3.17.6.tar.gz
"
